﻿using System;
using System.ComponentModel.DataAnnotations;

namespace SimpleScrum.Core.Entities
{
    public class Sprint
    {
        [Display(Name = "Sprint ID")]
        public virtual Guid Id { get; protected set; }

        [Required]
        [DataType(DataType.Text)]
        [Display(Name = "Sprint Name")]
        [StringLength(50, ErrorMessage = "The Sprint Name must be at most 50 characters long")]
        public virtual string Name { get; set; }

        [Required]
        [DataType(DataType.MultilineText)]
        [Display(Name = "Sprint Description")]
        [StringLength(500, ErrorMessage = "The Sprint Description must be at most 500 characters long")]
        public virtual string Description { get; set; }

        [Display(Name = "Version No")]
        public virtual int VersionNo { get; set; }

        [Required]
        [DataType(DataType.DateTime)]
        [Display(Name = "Started Date")]
        public virtual DateTime StartDate { get; set; }

        [Required]
        [DataType(DataType.DateTime)]
        [Display(Name = "End Date")]
        public virtual DateTime EndDate { get; set; }

        [Required]
        [Display(Name = "Project")]
        public virtual Project Project { get; set; }
    }
}